/**
 * 
 */
package com.fbty.mt.domain;

/**
 * @author freedom
 * 
 */
public class CheckInfo {
	
	
	public final static int SOCKS5_PROXY = 1; //代理类别 S5代理
	public final static int HTTPS_PROXY = 2; //https代理
	public final static int HTTP_PROXY = 3;  //http代理
	public final static int SOCKS4_PROXY = 4; //s4代理
	
	public static final int PROXY_CHECK_SUCCESS = 0 ;  //代理检测成功，除此以外的表示都为失败
	public static final int NO_PROXY = 1 << 16;  //代理不存在
	public static final int PROXY_NO_CONNECT = 2 << 16; //代理无法连接
	public static final int PROXY_IO_ERROR = 3 << 16; //代理IO输出错误
	public static final int PROXY_AUTH_FAILURE = 4 << 16; //代理鉴权失败，帐号或者密码错误
	public static final int PROXY_CHECK_FAILURE = 5 << 16; //代理检测网址失败，即本地到代理服务器是正常的，但是通过代理到监测地址存在异常
	public static final int UNKNOWN_EXCEPTION = 6 << 16; //未知异常，程序内部错误

	/**
	 * 本地服务器到代理服务器的延迟
	 */
	private long delay;
	/**
	 * 代理服务器地址
	 */
	private String host;
	/**
	 * 监测代理类别
	 */
	private int checkType;
	/**
	 * 监测结果
	 */
	private int reslut;
	
	/**
	 * 端口
	 */
	private int port;
	
	
	public void setPort(int port) {
		this.port = port;
	}
	
	public void setReslut(int reslut) {
		this.reslut = reslut;
	}
	
	public int getPort() {
		return port;
	}
	
	public int getReslut() {
		return reslut;
	}

	public long getDelay() {
		return delay;
	}

	public void setDelay(long delay) {
		this.delay = delay;
	}

	public String getHost() {
		return host;
	}

	public void setHost(String host) {
		this.host = host;
	}

	public int getCheckType() {
		return checkType;
	}

	public void setCheckType(int checkType) {
		this.checkType = checkType;
	}
	
	@Override
	public String toString() {
		
		return "host:"+host+"\n port:"+port+"\n delay:"+delay+"\n checkType:"+checkType+"\n reslut:"+reslut;
	}

}
